Fix hiding popover when focus moves outside
authorPhillip Wood <phillip.wood@dunelm.org.uk>
Mon, 25 Apr 2016 12:16:21 +0000 (13:16 +0100)
committerMatthias Clasen <mclasen@redhat.com>
Mon, 6 Jun 2016 02:54:00 +0000 (22:54 -0400)
commit72ea348ad624c184aed437704e5a31e5eefb16cc
treee15fc2f2d7efc261102b9f0ded0cee0613ae9a7d
parent0943c9f6b2c3ad5827ae5d8f3742f75e72782e41
Fix hiding popover when focus moves outside

Commit a01fe14 changed the behaviour of popovers when the focus leaves
them to stop child popovers being hidden when the focus leaves their
parent. However they are now a bit too reluctant to hide - if the
focus passes to an unrelated popover the first popover is not
hidden. Also if the focus passes to another widget that does not
perform a gtk grab then the popover isn't hidden until the user
presses a non-movement key or clicks outside the popover.

The solution is to go back to checking if the focused widget is a
descendant of the popover, but to include popovers and their related
widgets in the ancestry chain.

https://bugzilla.gnome.org/show_bug.cgi?id=765595
gtk/gtkpopover.c